-
Notifications
You must be signed in to change notification settings - Fork 124
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
dependency upgrades #682
dependency upgrades #682
Conversation
…>= 3.7 possibly >= 3.6, worked fine in 3.5
The version pins for the respective packages in |
…A-project/climada_python into feature/conda_environment
What's the best way to go about checking if everything works? I guess installing climada from scratch with the updated env? And then just try out things that aren't covered by unit tests, like some tutorials, etc.? And things in petals, since they would also be affected by this? I could imagine that especially shapely changes mainly affect our work routine around climada.. |
I was trying as said, with an updated
|
@Evelyn-M Your conda is still running on Python 3.7 and seems outdated. Before debugging the problem, try updating conda (should be |
So shapely >= 2.0 and rasterio 1.3 were not installable for me in the same environment:
If I understand it correctly, the cartopy <0.20.3 is the issue, as it requires a geos version which is not installable with the other two mentioned packages? |
So, for all hdf5 objects which are loaded during unittests, i get this sort of warning that concerns
code which uses the .get_map() method of matplotlib receives this deprecation warning now concerning
for instance, in
Apart from that, i found no issues so far with the dependency upgrades. |
@Evelyn-M The latest version of cartopy is 0.21. Try removing the cartopy version restriction as I mentioned here: #655 (comment) |
I already did that in the last commit (1f0e6da) |
@Evelyn-M The easiest way to an upgraded environment is probably to create a new environment, install climada from conda-forge, downgrade eccodes to 2.26, then install climada again with I'll take care of to update the climada_env file, so that the usual installation procedure works again. |
@@ -731,7 +731,8 @@ def _get_litpop_single_polygon(polygon, reference_year, res_arcsec, data_dir, | |||
global_origins=global_origins, | |||
) | |||
except ValueError as err: | |||
if "height must be > 0" in err.args[0] or "width must be > 0" in err.args[0]: | |||
if ("height must be > 0" in str(err) or "width must be > 0" in str(err) # rasterio 1.2 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We do not allow rasterio v1.2 anymore, so this case could be removed, right?
requirements/env_climada.yml
Outdated
- cfgrib>=0.9.7,<0.9.10 # 0.9.10 cannot read the icon_grib files from https://opendata.dwd.de | ||
- contextily>=1.0 | ||
- dask>=2.25 | ||
- gdal!=3.4.1 # has an issue with fiona on Windows (#403) | ||
- geopandas>=0.8 | ||
- h5py>=2.10 | ||
- haversine>=2.3 | ||
- matplotlib>=3.2,<3.6 # 3.6 requires cartopy 0.21 (s. https://github.com/SciTools/cartopy/pull/2054) | ||
- matplotlib==3.7 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think pinning a version is dangerous because we might get incompatible environments more quickly. What is the reason to pin to matplotlib v3.7?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I plan to set minimal version numbers for all dependencies according to the currently installed versions (union between Windows, Linux and MacOS) for the develop branch. Hence the env_climada.yml is bound to change!
For the releases (and for the Conda spec) I'm going to to completely fix the version numbers of all dependencies (but not the builds). The idea is to help with reproducibility and in the mean time avoid trouble shooting conda installations.
This will not succeed completely because the indirect dependencies still have some flexibility, but at least it's a start.
In setup.py on the other hand, I don't plan to change anything, because - if someone is able to install climada based on pip alone, they must be mighty savvy and probably have their own agenda. (E.g. Euler)
Th PR is merged without review for now. Just to see the impact in Jenkins. |
Changes proposed in this PR:
This PR fixes
PR Author Checklist
develop
)PR Reviewer Checklist